<?php $this->load->view("general/header");?>
<div id="customer" class="page_">
    <div class="form">              
        <div class="form_header">Bayar Sewa Mobil ke Owner Mobil</div>
        <div class="form_header_right"></div>
         
        <div class="form_header_right1"></div>
        <div class="content_dataS">
        <form method="post" action="<?php echo site_url("car/index");?>">
            <div class="content_dataR">
           		
               
                <div class="row">
                    <div class="col1"></div>
                    <div class="col2"> 
                        <div class="errorField"></div>
                    </div>
                </div>
                <div class="row">
                    <div class="col1">Agency/Owner</div>
                    <div class="col2">
                    	<select id="nama_pemilik" name="nama_pemilik">
                            <option value="" selected="selected">Pilih Agency</option>
                            <?php foreach ($owner as $owner1){?>
                                <option value="<?php echo $owner1['owner_id'];?>"><strong><?php echo $owner1['owner_name'];?></option>
                            <?php }?>
                    	</select>
                        <div class="errorField"><?php echo form_error("tarif");?></div>
                    </div>
                </div>
                <div class="row">
                    <div class="col1">Tahun Pembuatan</div>
                    <div class="col2"><input type="text" name="tahun"/> 
                        <div class="errorField"><?php echo form_error("tahun");?></div>
                    </div>
                </div>

                <div class="row">
                    <div class="col1">Masa Berlaku STNK</div>
                    <div class="col2">
                    	Bulan 
                        <select id="bln" name="bln" style="width:20%">
                            <?php for($i=1;$i<13;$i++){?>
                                <option value="<?php if($i<10){echo 0;} echo $i;?>"><?php  echo $i;?></option>
                            <?php }?>                   
                        </select>
                        
                        Tahun
                    	<select name="thn" style="width:30%">
							<?php for($i=date("Y")-10;$i<date("Y")+10;$i++){?>
                                <option value="<?php echo $i;?>"><?php if($i<10){echo 0;} echo $i;?></option>
                            <?php }?>                   
                   		</select> 
                        <div class="errorField"><?php echo form_error("masa_stnk");?></div>
                    </div>
                </div>
                <div class="row">
                    <div class="col1">Pembayaran dari tanggal</div>
                    <div class="col2"><input type="text" name="tanggal_pinjam" class="txtdate"/> 
                        <div class="errorField"><?php echo form_error("tanggal_pinjam");?></div>
                    </div>
                </div>
                <div class="row">
                    <div class="col1">Pembayaran sampai tanggal</div>
                    <div class="col2"><input type="text" name="tanggal_kembali" class="txtdate" /> 
                        <div class="errorField"><?php echo form_error("tanggal_kembali");?></div>
                    </div>
                </div>  
                <div class="row">
                    <div class="col1">Tarif/Hari Mobil</div>
                    <div class="col2"><input type="text" name="tarif" /> 
                        <div class="errorField"><?php echo form_error("tarif");?></div>
                    </div>
                </div>
                
                <div class="row">
                    <div class="col1">Harga Sewa</div>
                    <div class="col2"><input type="text" name="harga_sewa" /> 
                        <div class="errorField"><?php echo form_error("harga_sewa");?></div>
                    </div>
                </div>
                
                              
            </div>
            <div  style="border-bottom:solid; width:80%"><strong>Data Mobil</strong></div>
            <div class="row">
            	<div class="col1">Staff</div>
                <div class="col2"><?php echo get_username($this->session->userdata("user_id"));?> 
                	
                </div>
			</div>
            
            <div class="row">
            	<div class="col1">Nomor Polisi</div>
                <div class="col2"><input type="text" name="plat_mobil" /> 
                	<div class="errorField"><?php echo form_error("plat_mobil");?></div>
                </div>
			</div>

            <div class="row">
            	<div class="col1">Produsen</div>
                <div class="col2">
                	<select id="produsen" name="produsen">
                    <option value="" selected="selected">Pilih nama produsen</option>
                    	<option value="Toyota">Toyota</option>
                        <option value="Honda">Honda</option>
                        <option value="Suzuki">Suzuki</option>                    
                    </select>
                	<div class="errorField"><?php echo form_error("produsen");?></div>
                </div>
			</div>
            <div class="row">
            	<div class="col1">Tipe</div>
                <div class="col2">
               	 	<select id="tipe" name="tipe">
                    	<option value="" selected="selected">Pilih tipe mobil</option>
                    	<option value="Sedan">Sedan</option>
                        <option value="MPV">MPV</option>
                        <option value="SUV">SUV</option>                
                    </select>
                	<div class="errorField"><?php echo form_error("tipe");?></div>
                </div>
			</div>
            <div class="row">
            	<div class="col1">Model</div>
                <div class="col2"><input type="text" name="model" /> 
                	<div class="errorField"><?php echo form_error("model");?></div>
                </div>
			</div>
        	<div class="row">
            	<div class="col1">Series</div>
                <div class="col2"><input type="text" name="nama_mobil" /> 
                	<div class="errorField"><?php echo form_error("nama_mobil");?></div>
                </div>
            </div>
			<div class="row">
            	<div class="col1">Warna Mobil</div>
                <div class="col2"><input type="text" name="warna" /> 
                	<div class="errorField"><?php echo form_error("warna");?></div>
                </div>
			</div>
           	<div class="row">
                <div class="col1">Daya Angkut</div>
                <div class="col2">
                	<select id="daya" name="daya">
                    	<option value="" selected="selected">Pilih daya angkut</option>
                        <option value="5">5 Orang</option>
                        <option value="7">7 Orang</option>
                        <option value="10">10 Orang</option>
                        <option value="12">12 Orang</option>                   
                    </select> 
                    <div class="errorField"><?php echo form_error("daya");?></div>
                </div>
            </div>
            <div class="row">
                <div class="col1">Mesin</div>
                <div class="col2"><input type="text" name="mesin" /> cc
                    <div class="errorField"><?php echo form_error("mesin");?></div>
                </div>
            </div>
            <div class="row">
                <div class="col1">Transmisi</div>
                <div class="col2">
                	<select id="transmisi" name="transmisi">
                    	<option value="" selected="selected">Pilih jenis transmisi</option>
                        <option value="Automatic">Automatic</option>
                    	<option value="Manual">Manual</option>               
                    </select> 
                    <div class="errorField"><?php echo form_error("transmisi");?></div>
                </div>
            </div>          
            <div class="row">
                <div class="col1">Bahan bakar</div>
                <div class="col2">
                	<select id="bensin" name="bensin">
                    	<option value="" selected="selected">Pilih jenis bahan bakar</option>
                        <option value="Premium">Premium</option>
                    	<option value="Pertamax">Pertamax</option>  
                        <option value="Bio Solar">Bio Solar</option>                
                    </select>
                    <div class="errorField"><?php echo form_error("bensin");?></div>
                </div>
            </div>
        
        </div>   
        <div class="title" align="right">
            <input type="submit" name="btnSave" value="Save" class="button_red" />
        </div>
        <div class="success"><?php echo (isset($success))?$success:"";?>&nbsp;</div>
        </form>
        
        
    </div>
</div>
<?php $this->load->view("general/footer");?>